1. Field of the Invention
The present invention relates to an image processor and image processing method which may be adapted, for example, to an image processor such as television receiver, video tape recorder, television camera and printer or the like. The present invention judges a domain to which image data belongs, for example, with reference to low frequency element of a pixel value and compensates for signal level of image data based on the result of judgment in order to compensate for gradation by effectively avoiding deterioration of partial contrast.
2. Description of the Related Art
In an image processor such as television camera or the like of the related art, an output signal is provided after compensation for gradation of image data which is obtained through an image input means such as an image sensing means.
FIG. 15 is a characteristic curve illustrating an input/output characteristic of a signal processing circuit adapted to such gradation compensating process. A signal processing circuit of this type reduces the gain when an input level 1 exceeds the predetermined reference level 1k. Thereby, the signal processing circuit of this type outputs a suppressed signal level when the input level becomes higher than the reference level 1k. In this case, gradation is compensated by sacrificing contrast of the part in the higher signal level.
In the characteristic curve of FIG. 15, the horizontal axis shows a pixel value l indicating an input level of image data, while the vertical axis shows a pixel value T(l) indicating an output level of image data. Moreover, Lmax shows the maximum level which each pixel of input/output image can take. In the following explanation, a function indicating an input/output relationship as indicated in the characteristic curve is called a level conversion function.
FIG. 16 is a characteristic curve showing the input/output characteristic of a signal processing circuit of the same type. The signal processing circuit based on this level conversion function reduces the gain when the input level 1 is the first reference level 1s or less and the second reference level 1b or more. Thereby, this signal processing circuit is caused to compensate for gradation by sacrificing contrast at the part of low signal level and high signal level.
Meanwhile, in the image processing utilizing a computer, gradation is compensated, for example, by histogram equalization.
In this histogram equalization method, the level conversion function is adaptively changed depending on frequency distribution of pixel value if an input image and moreover gradation is compensated by reducing gradation of the part having lower frequency distribution of pixel value.
Namely, as illustrated in FIG. 17, in the process of histogram equalization, accumulated frequency distribution C(1) by the arithmetic operation of the following formula is detected based on the frequency distribution H(1) which is collection of the number of pixels with reference to the pixel value l of the input image.                               C          ⁡                      (            1            )                          =                              ∑                          h              =              0                        1                    ⁢                      H            ⁡                          (              k              )                                                          (        1        )            
In the histogram equalization process, the level conversion function T(l) is defined by normalizing the accumulated frequency distribution C(l) detected as explained above with the following formula and the signal level of input image is compensated depending on this level conversion function T(l). Here, Fmax is the final value of the accumulated frequency distribution C(l) and Lmax is the maximum value of the input/output level.                               T          ⁡                      (            1            )                          =                                            C              ⁡                              (                1                )                                      Fmax                    ×          Lmax                                    (        2        )            
Such process to compensate for gradation is executed as required for suppression of dynamic range even when image data is transmitted to the transmission line and when image data is displayed on a display unit or when image data is stored in a storage apparatus.
In the gradation compensating process by the method of the related art, total gradation is compensated by sacrificing contrast of a certain part in order to avoid generation of unnatural image and to convert the level with the input/output function having the monotonous increasing characteristic even in any kind of method.
Therefore, the method of the related art has a problem that contrast is partially lowered in the processed image.